package com.mxx.common.netty;

import com.mxx.common.netty.http.NettyMethod;
import com.mxx.common.netty.http.NettyHttpRequest;
import com.mxx.common.netty.http.NettyHttpResponse;
import com.mxx.common.netty.interceptor.Finish;
import io.netty.channel.ChannelHandlerContext;
import io.netty.handler.codec.http.FullHttpRequest;

/**
 * @Auther: Mr. Zeng
 * @Date: 2020/7/17 18:18
 * @Description: 暂无描述
 */
public interface NettyHttpOperator {

    void doRead(ChannelHandlerContext ctx, FullHttpRequest request);

    void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception;

    interface InterceptorExecute {
        Finish doInterceptor(NettyHttpRequest nettyHttpRequest, NettyHttpResponse nettyHttpResponse, NettyMethod processor);
    }
}
